layui.define(['jqform'], function (exports) {
     var $ = layui.jquery;
     var  layer = layui.layer;
     var form = layui.jqform;

     $('#btn_save').click(function(){
        if($("#accept_id").val()==""){layer.msg("请选择通知对象");return false;}
        if($("#content").val()==""){layer.msg("请填写通知内容");return false;}
        if ($('input[type="checkbox"][name="no_flag[]"]:checked').each(function (i) {
            }).length == 0) {
                layer.msg('请选择通知方式');
                return false;
            }
        $.post('/html/notice/srv/edit_notice.php',$('#form1').serialize(),function(e){
            layer.alert(e, function(index){
              parent.layer.close(parent.layer.getFrameIndex(window.name))
            });  
        })
     });
	
     exports('notice_edit', {});
});